home *** CD-ROM | disk | FTP | other *** search
/ Geek Gadgets 2 / Geek_Gadgets_2_2352.bin / lists / ade-gcc.archive.9602.gz / ade-gcc.archive.9602 / 000053_owner-ade-gcc_Wed Feb 14 06:04:54 1996.msg < prev    next >
Internet Message Format  |  1996-02-28  |  2KB

  1. Return-Path: <owner-ade-gcc>
  2. Received: by fishpond (Smail3.1.29.1 #57)
  3.     id m0tmf11-000gYJa; Wed, 14 Feb 96 06:04 EST
  4. Sender: owner-ade-gcc
  5. Received: from mail.gmd.de by fishpond with smtp
  6.     (Smail3.1.29.1 #57) id m0tmf0z-000gXUC; Wed, 14 Feb 96 06:04 EST
  7. Received: from diva.gmd.de (diva) by mail.gmd.de with SMTP id AA04248
  8.   (5.67b8/IDA-1.5 for <ade-gcc@amigalib.com>); Wed, 14 Feb 1996 12:02:37 +0100
  9. Received: by diva.gmd.de with UUCP id AA29188
  10.   (5.67b8/IDA-1.5); Wed, 14 Feb 1996 12:02:35 +0100
  11. Date: Wed, 14 Feb 1996 12:02:35 +0100
  12. Message-Id: <199602141102.AA29188@diva.gmd.de>
  13. From: Joerg.Hoehle@gmd.de (Joerg Hoehle)
  14. To: ADE GCC List <ade-gcc@amigalib.com>,
  15.         Amiga GCC List <amiga-gcc-port@nic.funet.fi>
  16. Subject: Re: Amiga-specific attributes implemented as keywords
  17. In-Reply-To: <Pine.SUN.3.91.960214112838.11454B-100000@ernie>
  18. References: <199602130949.AA28677@diva.gmd.de>
  19.     <Pine.SUN.3.91.960214112838.11454B-100000@ernie>
  20. Sender: owner-ade-gcc@amigalib.com
  21. Precedence: bulk
  22.  
  23. Kamil Iskra writes:
  24.  > > Unluckily, stack growth is currently at function entry, not within
  25.  > > ("call function <a> with at least 40KB (dynamically computed) of stack").
  26.  > 
  27.  > What do you mean? I don't really follow you... 
  28.  
  29. I mean that usually, you want something like the following:
  30.  
  31. in function A:
  32.    "oh, this is our input, it's so complex that we'll need
  33.    ... compute stack size as a function of the input ...
  34.    ah, 40KB of stack before calling function B, so let's reserve
  35.    that much and call B so that it'll have enough."
  36.  
  37. and not:
  38. at function entry of B:
  39.    "oh, well, I probably need a bigger stack, but how much, 2KB, 10KB
  40.    or 100KB?"
  41.  
  42. Unfortunately, the latter is what stackextend gives you.  Currently,
  43. you could be smart and set the stackextend variable to 100KB in A and
  44. reset it to a normal 4KB in B, so that at entry of B, the stack will
  45. be extended if it's not already 100KB in size.  But this splitting
  46. among two functions is cumbersome.  You need to reset the variable in
  47. B because you don't want every other function called by B to reserve
  48. 100KB again.
  49.  
  50. Bye,
  51.      Joerg Hoehle.
  52. Joerg.Hoehle@gmd.de            hoehle@zeus.gmd.de